<?php

namespace app\models;

use Yii;

/**
 * This is the model class for table "t_base_sms_log".
 *
 * @property string $id
 * @property string $mobile
 * @property string $device_id
 * @property string $content 编码（外部唯一标识）
 * @property string $msg_id
 * @property string $type 1注册2找回密码
 * @property string $create_time
 */
class TBaseSmsLog extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 't_base_sms_log';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['id','mobile', 'content', 'type', 'create_time'], 'required'],
            [['create_time'], 'safe'],
            [['mobile'], 'string', 'max' => 15],
            [['device_id'], 'string', 'max' => 50],
            [['content'], 'string', 'max' => 2000],
//            [['msg_id', 'type'], 'string', 'max' => 255],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'mobile' => 'Mobile',
            'device_id' => 'Device ID',
            'content' => 'Content',
            'msg_id' => 'Msg ID',
            'type' => 'Type',
            'create_time' => 'Create Time',
        ];
    }
}
